/* 搜索页面样式 */
.search-page {
  min-height: 100vh;
  background-color: #f5f5f5;
}

/* 搜索头部 */
.search-header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background-color: #f8f9fa;
  border-bottom: 1px solid #e9ecef;
  position: relative;
}

.search-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-right: 12px;
  cursor: pointer;
  color: #666;
}

.search-back:hover {
  color: #333;
}

.search-input-container {
  flex: 1;
  margin-right: 12px;
  position: relative;
}

.search-input {
  width: 90%;
  height: 36px;
  padding: 0 12px;
  border: none;
  border-radius: 18px;
  background-color: #fff;
  font-size: 14px;
  outline: none;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.search-input::placeholder {
  color: #999;
}

/* 搜索建议 */
.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: white;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  margin-top: 4px;
  max-height: 200px;
  overflow-y: auto;
}

.suggestion-item {
  padding: 12px 16px;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
  transition: background-color 0.2s;
}

.suggestion-item:last-child {
  border-bottom: none;
}

.suggestion-item:hover {
  background-color: #f8f9fa;
}

.search-button {
  height: 36px;
  padding: 0 16px;
  border: none;
  border-radius: 18px;
  background-color: #1890ff;
  color: white;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s;
}

.search-button:hover {
  background-color: #40a9ff;
}

.search-button:active {
  background-color: #096dd9;
}

/* 搜索内容区域 */
.search-content {
  padding: 16px;
}

/* 搜索历史 */
.search-history {
  background-color: white;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}

.history-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.history-title {
  font-size: 16px;
  font-weight: 600;
  color: #1890ff;
}

.clear-history {
  background: none;
  border: none;
  color: #999;
  font-size: 14px;
  cursor: pointer;
  padding: 4px 8px;
}

.clear-history:hover {
  color: #666;
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.history-item {
  padding: 12px 16px;
  background-color: #f8f9fa;
  border-radius: 6px;
  font-size: 14px;
  color: #333;
  cursor: pointer;
  transition: background-color 0.2s;
}

.history-item:hover {
  background-color: #e9ecef;
}

/* 搜索结果 */
.search-results {
  background-color: white;
  border-radius: 8px;
  padding: 16px;
}

.loading {
  text-align: center;
  padding: 40px;
  color: #999;
  font-size: 14px;
}

.no-results {
  text-align: center;
  padding: 40px;
  color: #999;
  font-size: 14px;
}

.results-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.result-item {
  padding: 16px;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.result-item:hover {
  border-color: #1890ff;
  box-shadow: 0 2px 8px rgba(24, 144, 255, 0.1);
}

.result-header {
  margin-bottom: 8px;
}

.result-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #333;
  line-height: 1.4;
}

.result-time {
  font-size: 12px;
  color: #999;
  margin-bottom: 8px;
}

.result-detail {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.result-actions {
  display: flex;
  gap: 16px;
}

.result-collection,
.result-comment {
  font-size: 12px;
  color: #999;
  cursor: pointer;
  transition: color 0.2s;
}

.result-collection:hover,
.result-comment:hover {
  color: #1890ff;
}

/* 响应式设计 */
@media (max-width: 480px) {
  .search-header {
    padding: 8px 12px;
  }
  
  .search-content {
    padding: 12px;
  }
  
  .result-item {
    padding: 12px;
  }
  
  .result-title {
    font-size: 15px;
  }
  
  .result-detail {
    font-size: 13px;
  }
  
  .search-suggestions {
    margin-top: 2px;
  }
}
